/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package util.jQgrid;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import com.google.gson.Gson;

/**
 *
 * @author CHANWUT
 */
public class JSONUtil {
    
    private static final Log logger = LogFactory.getLog(JSONUtil.class);

    public static String convertToJSON(Object obj) {
        String json = null;
        Gson gson = new Gson();
        json = (gson.toJson(obj));
        logger.debug(json);
        return json;
    }
}
